import StartHome from '../pages/agent/start/StartHome'
import Agent from '../pages/Agent'
import NeedHome from '../pages/agent/need/NeedHome'
import MyHome from '../pages/agent/my/MyHome'
import ContractNew from '../pages/agent/contract/ContractNew'
import NeedNew from '../pages/agent/need/NeedNew'
import StartNew from '../pages/agent/start/StartNew'
import StartGoods from '../pages/agent/start/StartGoods'
import DataHome from '../pages/agent/data/dataHome'
import DataNew from '../pages/agent/data/dataNew'
import MyPassword from '../pages/agent/my/MyChangePassword'
import MySurplus from '../pages/agent/my/MySurplus'
import StartDrafts from '../pages/agent/start/StartDrafts'
import NeedDrafts from '../pages/agent/need/NeedDrafts'
import MyStartDetailed from '../pages/agent/my/detailed/MyStartDetailed'
import CustomerNeedHome from '../pages/agent/customerNeed/CustomerNeedHome'
import CustomerNeedNew from '../pages/agent/customerNeed/CustomerNeedNew'
import MyContractDetailed from '../pages/agent/my/detailed/MyContractDetailed'
import MyNeedDetailed from '../pages/agent/my/detailed/MyNeedDetailed'
import MyDataDetailed from '../pages/agent/my/detailed/MyDataDetailed'
import CustomerNeedDrafts from "../pages/agent/customerNeed/CustomerNeedDrafts";

const agent = [
  {
    path: '/agent',
    name: 'agent',
    component: Agent,
    children: [
      // 登陆单
      {
        path: 'start',
        name: 'agent-start',
        component: StartHome,
        meta: {index: 0}
      },
      {
        path: 'start/goods',
        name: 'agent-start-goods',
        component: StartGoods
      },
      {
        path: 'start/new',
        name: 'agent-start-new',
        component: StartNew
      },
      {
        path: 'start/drafts',
        name: 'agent-start-drafts',
        component: StartDrafts,
      },
      // 工程合同
      {
        path: 'contract/new',
        name: 'agent-contract-new',
        component: ContractNew
      },
      //要货单
      {
        path: 'need',
        name: 'agent-need',
        component: NeedHome,
        meta: {index: 2}
      },
      {
        path: 'need/new',
        name: 'agent-need-new',
        component: NeedNew
      },
      {
        path: 'need/Drafts',
        name: 'agent-need-drafts',
        component: NeedDrafts
      },
      // 我的
      {
        path: 'my',
        name: 'agent-my',
        component: MyHome,
        meta: {index: 4}
      },
      {
        path: 'my/password',
        name: 'change-password',
        component: MyPassword,
      },
      {
        path: 'my/surplus',
        name: 'surplus',
        component: MySurplus,
      },
      {
        path: 'my/search/start/detailed',
        name: 'my-start-detailed',
        component: MyStartDetailed
      },
      {
        path: 'my/contract/detailed',
        name: 'my-contract-detaild',
        component: MyContractDetailed
      },
      {
        path: 'my/need/detailed',
        name: 'my-need-detailed',
        component: MyNeedDetailed
      },
      {
        path: 'my-data-detailed',
        name: 'my-data-detailed',
        component: MyDataDetailed
      },
      {
        path: 'data',
        name: 'agent-data',
        component: DataHome,
        meta: {index: 3}
      },
      {
        path: 'data/new',
        name: 'agent-data-new',
        component: DataNew
      },
      //客户要货单
      {
        path: 'customerNeed',
        name: 'agent-customerNeed',
        component: CustomerNeedHome,
        meta: {index: 1}
      },
      {
        path: 'customerNeed/new',
        name: 'agent-customerNeed-new',
        component: CustomerNeedNew
      },
      {
        path: 'customerNeed/drafts',
        name: 'agent-customerNeed-drafts',
        component: CustomerNeedDrafts,
      }
    ]
  }
]

export default agent
